import request from "@/utils/request";

// 查询房间信息
export function getRoomList(searchRoom) {
  return request({
    url: '/room/findAll',
    method: 'post',
    data: searchRoom
  })
}

// 删除房间信息
export function delRoomById(id) {
  return request({
    url: '/room/delRoomById',
    method: 'get',
    params: { id:id }
  })
}

// 批量删除房间信息
export function delRoomBatch(ids) {
  return request({
    url: '/room/delRoomByIds',
    method: 'get',
    params: ids
  })
}

// 添加房间信息
export function addRoom(data) {
  return request({
    url: '/room/addRoom',
    method: 'post',
    data
  })
}

// 修改房间信息
export function editRoom(data) {
  return request({
    url: '/room/updateRoom',
    method: 'post',
    data
  })
}


// 查询房间类型信息
export function findRoomType() {
  return request({
    url: '/room/findRoomType',
    method: 'get'
  })
}

// 导入房间信息
export function uploadExcel(formData) {
  return request({
    url: '/room/uploadExcel',
    method: 'post',
    data: formData
  })
}
